<div class="model_actions_toolbar">
    <?php $this->widget('backend.components.ToolbarFeedbacks'); ?>
</div>

<style type="text/css">
    .feedback { margin: 0 0 20px; }
    .feedback .title {
        margin-top: 20px;
        font-size: 1.5em; font-weight: bold; border-bottom: 1px solid #C9E0ED;
    }
    .feedback .username { color: #888; margin: 0 0 5px; line-height: 25px; }
    .comment {
        -moz-border-radius:7px;
        padding: 10px;
        background: #F5F5F5;
        margin: 5px 0;
    }
    .comment .content { margin: 10px 0; }
    .feedback .infos {
        -moz-border-radius: 7px;
        padding: 5px;
        background: #EFFDFF;
    }
    .infos ul { padding: 0; margin: 0; }
    .infos ul li { padding-right: 2px; line-height: 25px; }
    .infos ul li span { padding: 0 10px; color: #aaa; }
</style>


<div class="feedback">
    <div class="title">
        <?php echo CHtml::encode($feedback->title); ?>
    </div>
    <div class="username">
        Posted By <?php echo $feedback->username . " [ {$feedback->sexTextFormat} ] " . "（{$feedback->ip_address}）"  . ' on ' . date('Y-m-d H:m:s',$feedback->created); ?>
    </div>
    <div class="content">
        <?php
        $this->beginWidget('CMarkdown', array('purifyOutput'=>true));
        echo $feedback->body_formatted;
        $this->endWidget();
        ?>
    </div>
    <div class="infos">
        <ul>
            <li>
                <span><?php echo Yii::t('feedback', 'tel'); ?>：</span><?php echo $feedback->tel; ?>
                <span><?php echo Yii::t('feedback', 'fax'); ?>：</span><?php echo $feedback->fax; ?>
                <span><?php echo Yii::t('feedback', 'mobile_phone'); ?>：</span><?php echo $feedback->mobile_phone; ?>
            </li>
            <li>
                <span><?php echo Yii::t('feedback', 'address'); ?>：</span><?php echo $feedback->address; ?>
                <span><?php echo Yii::t('feedback', 'postcode'); ?>：</span><?php echo $feedback->postcode; ?>
            </li>
        </ul>
    </div>
</div>

<div class="commend">
    <?php if (Yii::app()->user->hasFlash('create_comment_success')): ?>
    <div class="success">
        <?php echo Yii::app()->user->getFlash('create_comment_success'); ?>
    </div>
    <?php elseif (Yii::app()->user->hasFlash('update_comment_success')): ?>
    <div class="success">
        <?php echo Yii::app()->user->getFlash('update_comment_success'); ?>
    </div>
    <?php endif; ?>
    <?php
    $this->renderPartial('/feedbacks/_comment',array(
        'comment' => $comment,
    ));
    ?>
</div>

